<div class="page-header">
  <span>{{widget_title}}</span>
  <button class="btn btn-xs btn-success pull-right" style="margin-top: 14.5px;" ng-click="editOrAdd('add')"> 添加持证要求 </button>
  <div class="clearfix"></div>
</div>
<table class="table table-hover table-bordered" >
  <thead>
    <tr>
      <th>序号</th>
      <th>审查机构</th>
      <th>岗位</th>
      <th>证书</th>
      <th>操作</th>
    </tr>
  </thead>
  <tbody>
    <tr ng-repeat-start="certificate_require in certificate_requires">
      <td rowspan="{{certificate_require.paper_types.length}}">{{$index + 1}}</td>
      <td rowspan="{{certificate_require.paper_types.length}}">{{certificate_require.manager.name}}</td>
      <td rowspan="{{certificate_require.paper_types.length}}">{{certificate_require.position.name}}</td>
      <td>{{certificate_require.paper_types[0].name}}</td>
      <td>
        <a class="btn btn-xs btn-info" ng-click="editOrAdd('edit', certificate_require.paper_types[0].require_id)">修改</a>
        <a class="btn btn-xs btn-danger" confirm-click agree-callback="deleteCertificateRequire(certificate_require.paper_types[0].require_id)"> 删除 </a>
      </td>
    </tr>
    <tr ng-repeat-end ng-repeat="certificate_type in certificate_require.paper_types.slice(1)">
      <td>{{certificate_type.name}}</td>
      <td>
        <a class="btn btn-xs btn-info" ng-click="editOrAdd('edit', certificate_type.require_id)">修改</a>
        <a class="btn btn-xs btn-danger" confirm-click agree-callback="deleteCertificateRequire(certificate_type.require_id)"> 删除 </a>
      </td>
    </tr>
  </tbody>
</table>
